package com.quick.controller;

import org.apache.shiro.authz.annotation.RequiresAuthentication;
import org.apache.shiro.authz.annotation.RequiresPermissions;
import org.apache.shiro.authz.annotation.RequiresRoles;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @author jojo.wang
 * @title: PermissionController
 * @projectName spring-boot-quick
 * @description: TODO
 * @date 2019/5/611:48
 */

@RestController
@RequestMapping("/security/permissions")
public class PermissionController {
    @RequestMapping("/get")
    @RequiresRoles("wwww")
    public String get(){
        return "有permission:retrieve这个权限的用户才能访问，不然访问不了";
    }
}
